﻿
@using Abp.Web.Mvc.Extensions
@using MyCompanyName.AbpZeroTemplate.Web.Navigation
@using MyCompanyName.AbpZeroTemplate.Web.Bundling
@using System.Threading
@using System.Web.Optimization
@using Abp.Extensions
@using Abp.MultiTenancy
@using Abp.Timing
@using Abp.Web.Mvc.Extensions
@using MyCompanyName.AbpZeroTemplate.Features
@using MyCompanyName.AbpZeroTemplate.Localization
@model  MyCompanyName.AbpZeroTemplate.Product.Dto.ProductInputDto

@{
    ViewBag.CurrentPageName = PageNames.App.ProductManager.ProductList;
}

@Html.IncludeScript("~/Areas/Mpa/Views/Product/CreteOrUpdate.js")
<style>
    .divflow {
        margin-left: -40px;
        margin-right: 0px;
    }
</style>
<div class="row">
    <div class="col-md-12">
        <div class="portlet light form-fit bordered">
            <div class="portlet-title" style="padding:8px 0px 0px 0px!important;">
                <!--标题-->
                <div class="col-md-3">
                    <div class="caption font-dark" style="padding-top:10px;font-size:15px;">
                        <i class="icon-settings font-dark"></i>
                        <span class="caption-subject bold uppercase"> 新增产品</span>
                    </div>
                </div>
                <div class="col-md-4">

                </div>
                <div class="col-md-3">

                </div>
                <div class="col-md-2">
                    <div class="btn-group" style="float:right;">
                        <button type="button" class="btn blue" onclick="history.back(-1);">返回</button>
                    </div>
                </div>

            </div>
            <div style="background-color:#0066b3;width:100%;height:2px;">
            </div>
            <!--内容-->
            <div class="portlet-body">
                <form action="#" id="form_sample_1" class="form-horizontal" novalidate="novalidate" style="overflow:hidden;">
                    <div class="form-body" style="overflow:hidden;">
                        <div class="row">
                            <div class="col-md-6">
                                <div class="form-group divflow">
                                    <label class="control-label col-md-4">
                                        产品编号
                                        <span class="required" aria-required="true"> * </span>
                                    </label>
                                    <div class="col-md-6">
                                        @if (@Model.ProductCode != null)
                                        {
                                            <input type="text" class="form-control" data-required="1" id="ProductCode" readonly="readonly" value="@Model.ProductCode">
                                            <input type="text" id="ProductId" value="@Model.Id" hidden="hidden">
                                        }
                                        else
                                        {
                                            <input type="text" class="form-control" data-required="1" id="ProductCode" placeholder="产品编号">
                                            <input type="text" id="ProductId" value="0" hidden="hidden">
                                        }
                                    </div>
                                </div>
                            </div>
                            <div class="col-md-6">
                                <div class="form-group divflow">
                                    <label class="control-label col-md-4">
                                        产品名称
                                        <span class="required" aria-required="true"> * </span>
                                    </label>
                                    <div class="col-md-6">
                                        <input id="ProductName" type="text" class="form-control" placeholder="产品名称" value="@Model.ProductName">
                                    </div>
                                </div>
                            </div>
                        </div>

                        <div class="row">
                            <div class="col-md-6">
                                <div class="form-group divflow">
                                    <label class="control-label col-md-4">
                                        产品类型
                                        <span class="required" aria-required="true"> * </span>
                                    </label>
                                    <div class="col-md-6">
                                        @*<input type="text" id="Address" data-required="1" class="form-control" placeholder="产品类型" value="@Model.ProductType">*@

                                        <select class="form-control" id="ProductType" placeholder="产品类型">
                                            <option value="1">包年</option>
                                            <option value="2">包半年</option>
                                            <option value="3">包季度</option>
                                            <option value="4">包月</option>
                                            <option value="5">包周</option>
                                        </select>
                                    </div>
                                </div>
                            </div>
                            <div class="col-md-6">
                                <div class="form-group divflow">
                                    <label class="control-label col-md-4">
                                        优先级
                                        <span class="required" aria-required="true"> * </span>
                                    </label>
                                    <div class="col-md-6">
                                        @*<input type="text" id="AlipayAccount" class="form-control" placeholder="优先级" value="@Model.ProductCode">*@

                                        <select class="form-control" id="Priority" placeholder="优先级" >
                                            <option value="1">一级</option>
                                            <option value="2">二级</option>
                                            <option value="3">三级</option>
                                            <option value="4">四有</option>
                                            <option value="5">五级</option>
                                        </select>
                                    </div>
                                </div>
                            </div>

                        </div>

                        <div class="row">
                            <div class="col-md-6">
                                <div class="form-group divflow">
                                    <label class="control-label col-md-4">
                                        生效日期
                                        <span class="required" aria-required="true"> * </span>
                                    </label>
                                    <div class="col-md-6">
                                        <input id="Effectivedate" type="text" class="form-control form-control-inline input-medium date-picker" placeholder="生效日期" value="@Model.Effectivedate">
                                    </div>
                                </div>
                            </div>
                            <div class="col-md-6">
                                <div class="form-group divflow">
                                    <label class="control-label col-md-4">
                                        结束日期
                                        <span class="required" aria-required="true"> * </span>
                                    </label>
                                    <div class="col-md-6">
                                        <input type="text" id="Invaliddate" data-required="1" class="form-control" placeholder="结束日期" value="@Model.Invaliddate">
                                    </div>
                                </div>
                            </div>
                        </div>

                        <div class="row">     
                            <div class="col-md-6">                    
                            <div class="form-group divflow">
                                <label class="control-label col-md-4">
                                    状态
                                    <span class="required" aria-required="true"> * </span>
                                </label>
                                <div class="col-md-6">
                                    <select class="form-control" id="Status" placeholder="状态">
                                        <option value="1">可用</option>
                                        <option value="0">停用</option>
                                    </select>
                                </div>
                            </div>
                            </div>
                        </div>

                        <div class="row">
                            <div class="col-md-12">
                                <div class="form-group divflow">
                                    <label class="control-label col-md-2">
                                        备注
                                    </label>
                                    <div class="col-md-8">
                                        <textarea id="Remark" data-required="1" class="form-control" placeholder="备注" rows="3">@Model.Remark</textarea>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                    <div class="form-actions" style="border-top:1px solid #0066b3;padding:20px;margin:0;">
                        <div class="row">
                            <div class="col-md-offset-10 col-md-9">
                                <button type="button" class="btn green" onclick="CreateSave('@(User.Identity.Name)');">提 交</button>
                                <button type="button" class="btn grey-salsa btn-outline" onclick="history.back(-1);">取 消</button>
                            </div>
                        </div>
                    </div>
                </form>
            </div>
        </div>
    </div>
</div>
